

#ifndef MODEL_H
#define	MODEL_H

#include <QtGui>

class Node;
class Model;

class Controller : QObject {
    Q_OBJECT

public:
    Controller();
    Controller(const Controller& orig) = delete;
    virtual ~Controller();

    /**
     * 
     * @param tree - a pointer to a NodeTop that is the root of the tree.
     * @param leaf - a pointer to the leaf that should be replaced with solution.
     */
    static void getSolution(Node* tree, Node* leaf);
    
    /**
     * Parses a string to a tree of nodes and returns a pointer to top of tree.
     * NOTICE: tree may not be correctly formed to place in model as it will
     * not have a top node.
     * 
     * @see parseTree.
     * @param 
     * @return 
     */
    static Node * parse(QString);
    void reparse(Node* tree, int inputPosition);
    
    
private:

};

#endif	/* MODEL_H */

